
#ifndef _1wire_H
#define _1wire_H

/** I N C L U D E S **********************************************************/
#include <xc.h>


/** P R O T O T Y P E S ******************************************************/
void OW_write_bit (unsigned char write_data);
unsigned char OW_read_bit (void);
unsigned char OW_reset_pulse(void);
void OW_write_byte (unsigned char write_data);
unsigned char OW_read_byte (void);

/*****************************************************************************
   V A R I A B L E S
******************************************************************************/

//Maxim search prototypes
// method declarations
int  OWFirst();
int  OWNext();
int  OWVerify();
void OWTargetSetup(unsigned char family_code);
void OWFamilySkipSetup();
int  OWSearch();

extern unsigned char ROM_NO[8];

extern unsigned char crc8;
unsigned char docrc8(unsigned char value);

#endif